import request from '@/utils/request'

export function getPermList() {
  return request({
    url: '/sys/permission'
  })
}

export function addPermList(data) {
  return request({
    url: '/sys/permission',
    method: 'post',
    data
  })
}

export function getPermById(id) {
  return request({
    url: '/sys/permission/' + id
  })
}

export function editPermById(data) {
  return request({
    url: '/sys/permission/' + data.id,
    method: 'put'
  })
}

export function delPermById(id) {
  return request({
    url: '/sys/permission/' + id,
    method: 'delete'
  })
}

